package com.xbongbong.dingtalkPay.service;

import com.taobao.api.ApiException;
import com.xbongbong.paas.toolbox.exception.XbbException;
import com.xbongbong.pro.dingtalkPay.pojo.dto.GetOrderInfoDTO;
import com.xbongbong.pro.dingtalkPay.pojo.dto.OrderConsumeDTO;
import com.xbongbong.pro.dingtalkPay.pojo.dto.OrderFinishDTO;
import com.xbongbong.pro.dingtalkPay.pojo.dto.SkupageGetDTO;
import com.xbongbong.pro.dingtalkPay.pojo.dto.UnfinishedOrderListDTO;
import com.xbongbong.pro.dingtalkPay.pojo.vo.GetOrderInfoVO;
import com.xbongbong.pro.dingtalkPay.pojo.vo.OrderConsumeVO;
import com.xbongbong.pro.dingtalkPay.pojo.vo.OrderFinishVO;
import com.xbongbong.pro.dingtalkPay.pojo.vo.SkupageGetVO;
import com.xbongbong.pro.dingtalkPay.pojo.vo.UnfinishedOrderListVO;

/**
 * @version v1.0
 * @desc 钉钉共创内购http服务方法类
 * @auther: youli.chen
 * @date: 2019-9-26
 * @since v1.0
 */
public interface DingtalkPayHttpService {

    /**
     * 获取内购商品SKU页面地址
     * @param skupageGetDTO
     */
    SkupageGetVO getSkuPage(SkupageGetDTO skupageGetDTO) throws XbbException;

    /**
     * 内购商品订单处理完成
     * @param orderFinishDTO
     * @return
     * @throws ApiException
     */
    OrderFinishVO orderFinish(OrderFinishDTO orderFinishDTO) throws XbbException;

    /**
     * 获取内购订单信息
     * @param getOrderInfoDTO
     * @return
     * @throws ApiException
     */
    GetOrderInfoVO getOrder(GetOrderInfoDTO getOrderInfoDTO) throws XbbException;

    /**
     * 应用内购商品核销
     * @param orderConsumeDTO
     * @return
     * @throws ApiException
     */
    OrderConsumeVO orderConsume(OrderConsumeDTO orderConsumeDTO) throws XbbException;

    /**
     * 获取未处理的已支付订单
     * @param unfinishedOrderListDTO
     * @return
     * @throws ApiException
     */
    UnfinishedOrderListVO getUnfinishedOrderList(UnfinishedOrderListDTO unfinishedOrderListDTO) throws XbbException;
}
